import {createRouter, createWebHistory} from 'vue-router'

import Home from '../views/Home/index.vue'

const router = createRouter({
    history: createWebHistory(import.meta.env.BASE_URL),
    routes: [
        {
            path: '/',
            name: 'home',
            component: Home
        },
        {
            path: '/login',
            name: 'login',
            component: () => import('../views/Login/index.vue')
        }, {
            path: '/register',
            name: 'register',
            component: () => import('../views/Register/index.vue')
        }, {
            path: '/search/:keyword',
            name: 'search',
            component: () => import('../views/Search/index.vue')
        },
    ]
})

export default router
